{include file="public/header" /}
<body>
<div class="x-body layui-anim">
    <form class="layui-form" id="form" action="{:url('save')}">
        {include file="public/arguments" /}
        <input type="hidden" name="id" value="{$Request.param.id}">
        <input type="hidden" name="pid" value="{$Request.param.pid|default=0}">
        {if $p_title }
        <div class="layui-form-item">
            <label class="layui-form-label">上级分类</label>
            <div class="layui-input-inline">
                <input type="text" class="layui-input" value="{$p_title}" disabled />
            </div>
        </div>
        {else}
        {include file="form/items/img" type='' /}
        {/if}
        <div class="layui-form-item">
            <label class="layui-form-label">分类名称</label>
            <div class="layui-input-inline">
                <input type="text" name="title" lay-verify="required" lay-reqtext="请输入分类名称" placeholder="请输入分类名称"
                       class="layui-input" value="{$info?$info.title:''}" autocomplete="off" />
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">排序</label>
            <div class="layui-input-inline">
                <input type="number" name="sort" lay-verify="required" lay-reqtext="请输入排序" placeholder="请输入排序"
                       class="layui-input" value="{$info?$info.sort:'0'}" autocomplete="off" />
            </div>
        </div>

        <div style="clear: both;height: 80px;"></div>
        <div class="layui-form-item layui-layout-admin">
            <div class="layui-input-block" style="min-height: 0!important;">
                <div class="layui-footer" style="left: 0;">
                    <button class="layui-btn" lay-filter="save" lay-submit formObj="#form">保存</button>
                </div>
            </div>
        </div>
    </form>
</div>
</body>
{include file="public/footer" /}
</html>